import { ApiProperty } from "@nestjs/swagger";
import { IsNotEmpty } from 'class-validator';

export class CreateLoginDto {
    @ApiProperty({
        description: '账号',
    })
    @IsNotEmpty()
    username: string;

    @ApiProperty({
        description: '密码',
    })
    @IsNotEmpty()
    password: string;

    @ApiProperty({
        description: '邮箱',
    })
    @IsNotEmpty()

    email: string;
    @ApiProperty({
        description: '花名',
    })
    nickName?: string;

    @ApiProperty({
        description: '电话号码',
    })
    phone?: string;

    @ApiProperty({
        description: '头像',
    })
    avator?: string;
}


export class LoginDto {
    @ApiProperty({
        description: '账号',
    })
    @IsNotEmpty()
    username: string;

    @ApiProperty({
        description: '密码',
    })
    @IsNotEmpty()
    password: string;
}